
<script>

var chart;
$(document).ready(function() {
	chart = new Highcharts.Chart({
		chart: {
			renderTo: 'container',
			plotBackgroundColor: null,
			plotBorderWidth: null,
			plotShadow: false,
            width: 360,
            height: 268
		},
		title: {
			text: 'Acessos x Pageviews'
		},
		tooltip: {
			formatter: function() {
				return '<b>'+ this.point.name +'</b>: '+ this.percentage +' %';
			}
		},
		plotOptions: {
			pie: {
				allowPointSelect: true,
				cursor: 'pointer',
				dataLabels: {
					enabled: false,
					color: '#000000',
					connectorColor: '#000000',
					formatter: function() {
						return '<b>'+ this.point.name +'</b>: '+ this.percentage +' %';
					}
				}
			}
		},
		series: [{
			type: 'pie',
			name: 'Browser share',
			data: [
            
                {foreach from=$lista item=listar}
                    ['Visitas', {$listar->getVisits()}],
                    ['Pageviews', {$listar->getPageviews()}],
                {/foreach}

			]
            
		}]
	});
});

</script>

<div id="container"></div>